package cn.wolfcode.wolf2w.repository;

import cn.wolfcode.wolf2w.domain.Banner;
import cn.wolfcode.wolf2w.domain.Spot;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.List;

/**
 * 游记推荐持久层接口
 */
public interface BannerRepository extends MongoRepository<Banner, String>{

    /**
     * 游记推荐显示前五个
     * @param type
     * @param state
     * @param pageable
     * @return
     */
    List<Banner> findByStateAndType(int type, int state, Pageable pageable);
}
